﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ServiceModel;
using System.Runtime.Serialization;

namespace WcfFlashRemoting.Example3.Contract
{
    [ServiceContract(Namespace = "urn:WcfFlashRemoting:Examples:Example3")]
    public interface IItemCheckContract
    {
        [OperationContract]
        StockData GetItemData(ItemDescription item);

        [OperationContract]
        StockData[] GetAllItemData();
    }

    [DataContract]
    public class StockData
    {
        [DataMember]
        public int Quantity { get; set; }
        [DataMember]
        public double Price { get; set; }
        [DataMember]
        public string Name { get; set; }
    }

    [DataContract]
    public class ItemDescription
    {
        [DataMember]
        public int ItemId { get; set; }
        [DataMember]
        public string Name { get; set; }
    }
}
